Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: add section to troubleshoot Avahi and mDNS #771

Merged
merged 3 commits into from
Sep 21, 2020
Merged

Conversation

mbologna
Copy link
Contributor

@mbologna mbologna commented Sep 15, 2020

What does this PR change?

I was having resolution problems with Avahi on an openSUSE 15.2 host trying to resolve a sumaformed Uyuni server:

opensuse # avahi-resolve -n uyuni.tf.local
uyuni.tf.local 192.168.122.154
# ping uyuni.tf.local
ping: uyuni.tf.local: Name or service not known
# ping 192.168.122.154
PING 192.168.122.154 (192.168.122.154) 56(84) bytes of data.
64 bytes from 192.168.122.154: icmp_seq=1 ttl=64 time=0.245 ms

The problem disappears when I change Avahi configuration in the Uyuni host to use the first-level domain local (instead of tf.local).

Turns out that in the newest version of nss-mdns (shipping with OpenSUSE 15.2), second-level .local domains must be explicitly allowed to be resolved in /etc/mdns.allow AND mdns (not mdns_minimal) must be used in nsswitch.conf.
The latter is already covered in the troubleshooting, I took care of adding the former information into the docs.

Upstream issue: avahi/nss-mdns#64
Upstream resolution (linked in sumaform docs): https://github.com/lathiat/nss-mdns/blob/master/README.md#etcmdnsallow

I was resolution problems with Avahi on an openSUSE 15.2 host trying to
resolve a sumaform'ed Uyuni server:

```
opensuse # avahi-resolve -n uyuni.tf.local
uyuni.tf.local 192.168.122.154
ping: uyuni.tf.local: Name or service not known
PING 192.168.122.154 (192.168.122.154) 56(84) bytes of data.
64 bytes from 192.168.122.154: icmp_seq=1 ttl=64 time=0.245 ms
```

The problem disappears when I change Avahi configuration in the Uyuni
host to use the first-level domain `local` (instead of `tf.local`).

Turns out that in the newest version of `nss-mdns` (shipping with
OpenSUSE 15.2), second-level `.local` domains must be explicitly allowed
to be resolved in `/etc/mdns.allow` AND `mdns` (not `mdns_minimal`) must
be used in `nsswitch.conf`.
The latter is already covered in the troubleshooting, I took care of
adding the former information into the docs.

Upstream issue: avahi/nss-mdns#64
Upstream resolution (linked in sumaform docs):
https://github.com/lathiat/nss-mdns/blob/master/README.md#etcmdnsallow
Copy link
Contributor

@witekest witekest left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also observe this behavior on openSUSE 15.2. Populating /etc/mdns.allow fixes the problem as described.

TROUBLESHOOTING.md Outdated Show resolved Hide resolved
Copy link
Contributor

@Bischoff Bischoff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some changes requested (a few nitpicks, but also something important i suggest using same contents for /etc/mdns.allow that sumaform uses 😸 )

TROUBLESHOOTING.md Outdated Show resolved Hide resolved
TROUBLESHOOTING.md Outdated Show resolved Hide resolved
TROUBLESHOOTING.md Show resolved Hide resolved
TROUBLESHOOTING.md Outdated Show resolved Hide resolved
@Bischoff Bischoff self-requested a review September 18, 2020 12:26
Copy link
Contributor

@Bischoff Bischoff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM now

@moio moio merged commit 49c16cc into master Sep 21, 2020
@moio moio deleted the fix/new_mdns_docs branch September 21, 2020 08:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants